<%@ page import="ihisab.LendingTransaction" %>



<div class="fieldcontain ${hasErrors(bean: lendingTransactionInstance, field: 'person', 'error')} required">
	<label for="person">
		<g:message code="lendingTransaction.person.label" default="Person" />
		<span class="required-indicator">*</span>
	</label>
	<g:select id="person" name="person.id" from="${ihisab.Person.list()}" optionKey="id" required="" value="${lendingTransactionInstance?.person?.id}" class="many-to-one"/>
</div>

<div class="fieldcontain ${hasErrors(bean: lendingTransactionInstance, field: 'amount', 'error')} required">
	<label for="amount">
		<g:message code="lendingTransaction.amount.label" default="Amount" />
		<span class="required-indicator">*</span>
	</label>
	<g:field name="amount" value="${fieldValue(bean: lendingTransactionInstance, field: 'amount')}" required=""/>
</div>

<div class="fieldcontain ${hasErrors(bean: lendingTransactionInstance, field: 'interestAmount', 'error')} required">
	<label for="interestAmount">
		<g:message code="lendingTransaction.interestAmount.label" default="Interest Amount" />
		<span class="required-indicator">*</span>
	</label>
	<g:field name="interestAmount" value="${fieldValue(bean: lendingTransactionInstance, field: 'interestAmount')}" required=""/>
</div>

<div class="fieldcontain ${hasErrors(bean: lendingTransactionInstance, field: 'fromDate', 'error')} required">
	<label for="fromDate">
		<g:message code="lendingTransaction.fromDate.label" default="From Date" />
		<span class="required-indicator">*</span>
	</label>
	<g:datePicker name="fromDate" precision="day"  value="${lendingTransactionInstance?.fromDate}"  />
</div>

<div class="fieldcontain ${hasErrors(bean: lendingTransactionInstance, field: 'toDate', 'error')} required">
	<label for="toDate">
		<g:message code="lendingTransaction.toDate.label" default="To Date" />
		<span class="required-indicator">*</span>
	</label>
	<g:datePicker name="toDate" precision="day"  value="${lendingTransactionInstance?.toDate}"  />
</div>

<div class="fieldcontain ${hasErrors(bean: lendingTransactionInstance, field: 'transactionType', 'error')} required">
	<label for="transactionType">
		<g:message code="lendingTransaction.transactionType.label" default="Transaction Type" />
		<span class="required-indicator">*</span>
	</label>
	<g:select name="transactionType" from="${lendingTransactionInstance.constraints.transactionType.inList}" required="" value="${lendingTransactionInstance?.transactionType}" valueMessagePrefix="lendingTransaction.transactionType"/>
</div>

<div class="fieldcontain ${hasErrors(bean: lendingTransactionInstance, field: 'comments', 'error')} ">
	<label for="comments">
		<g:message code="lendingTransaction.comments.label" default="Comments" />
		
	</label>
	<g:textField name="comments" value="${lendingTransactionInstance?.comments}"/>
</div>

